{extend name='base'/}
{block name='content'}
<ul class="breadcrumb no-border no-radius b-b b-light pull-in">
    <li><a href="index.html"><i class="fa fa-home"></i>Typeattr</a></li>
    <li><a href="#">类型属性管理</a></li>
    <li class="active">类型属性列表</li>
</ul>
<div class="col-sm-12">
    <section class="panel panel-default">
        <header class="panel-heading font-bold">{$type['tname']} --属性列表</header>
        <div class="panel-body">
            <div class="panel panel-default">
                <div class="panel-heading">
                    <h3 class="panel-title"><a href="{:url('admin/typeattr/add',['tid'=>input('param.tid')])}" class="btn btn-success btn-xs">添加属性</a></h3>
                </div>

            </div>
            <table class="table table-hover">
                <thead>
                <tr>
                    <th>taid</th>
                    <th>属性名称</th>
                    <th>属性值</th>
                    <th>属性类型</th>
                    <th>操作</th>
                </tr>
                </thead>
                {volist name="typeattr" id="data"}
                <tbody>
                    <tr>
                        <td>{$data['taid']}</td>
                        <td>{$data['taname']}</td>
                        <td>{$data['tavalue']}</td>
                        <td>
                            {if condition="($data['class'] == 0)"} 普通
                            {else /}规格
                            {/if}
                        </td>
                        <td>
                            <!-- Single button -->
                            <div class="btn-group">
                                <button type="button" class="btn btn-success btn-xs dropdown-toggle" data-toggle="dropdown">
                                    操作 <span class="caret"></span>
                                </button>
                                <ul class="dropdown-menu" role="menu">
                                    <li><a href="#">属性列表</a></li>
                                    <li><a href="{:url('admin/typeattr/edit',['taid'=>$data['taid']])}">编辑</a></li>
                                    <li><a href="{:url('admin/typeattr/del',['taid'=>$data['taid']])}">删除</a></li>
                                </ul>
                            </div>

                        </td>
                    </tr>
                </tbody>
                {/volist}
            </table>
        </div>
    </section>
</div>

{/block}
